package com.ruoyi.project.module.columnNameSearch.service;

import java.util.List;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Service;
import com.ruoyi.project.module.columnNameSearch.mapper.ColumnNameSearchMapper;
import com.ruoyi.project.module.columnNameSearch.domain.ColumnNameSearch;
import com.ruoyi.project.module.columnNameSearch.service.IColumnNameSearchService;
import com.ruoyi.common.support.Convert;
import javax.annotation.Resource;

/**
 * 字段参考 服务层实现
 * 
 * @author ruoyi
 * @date 2020-12-12
 */
@Service
public class ColumnNameSearchServiceImpl implements IColumnNameSearchService 
{
	@Resource
	private ColumnNameSearchMapper columnNameSearchMapper;

	/**
     * 查询字段参考信息
     * 
     * @param columnNameSearchId 字段参考ID
     * @return 字段参考信息
     */
    @Override
	public ColumnNameSearch selectColumnNameSearchById(Long columnNameSearchId)
	{
	    return columnNameSearchMapper.selectColumnNameSearchById(columnNameSearchId);
	}
	
	/**
     * 查询字段参考列表
     * 
     * @param columnNameSearch 字段参考信息
     * @return 字段参考集合
     */
	@Override
	public List<ColumnNameSearch> selectColumnNameSearchList(ColumnNameSearch columnNameSearch)
	{
	    return columnNameSearchMapper.selectColumnNameSearchList(columnNameSearch);
	}
	
    /**
     * 新增字段参考
     * 
     * @param columnNameSearch 字段参考信息
     * @return 结果
     */
	@Override
	public int insertColumnNameSearch(ColumnNameSearch columnNameSearch)
	{
	    return columnNameSearchMapper.insertColumnNameSearch(columnNameSearch);
	}
	
	/**
     * 修改字段参考
     * 
     * @param columnNameSearch 字段参考信息
     * @return 结果
     */
	@Override
	public int updateColumnNameSearch(ColumnNameSearch columnNameSearch)
	{
	    return columnNameSearchMapper.updateColumnNameSearch(columnNameSearch);
	}

	/**
     * 删除字段参考对象
     * 
     * @param ids 需要删除的数据ID
     * @return 结果
     */
	@Override
	public int deleteColumnNameSearchByIds(String ids)
	{
		return columnNameSearchMapper.deleteColumnNameSearchByIds(Convert.toStrArray(ids));
	}
	
}
